Optimal. Leaf size=159 \[ \frac {F_1\left (1+n;-\frac {1}{2},-\frac {1}{2};2+n;\frac {a+b \tan (c+d x)}{a-\sqrt {-b^2}},\frac {a+b \tan (c+d x)}{a+\sqrt {-b^2}}\right ) \sec (c+d x) (a+b \tan (c+d x))^{1+n}}{b d (1+n) \sqrt {1-\frac {a+b \tan (c+d x)}{a-\sqrt {-b^2}}} \sqrt {1-\frac {a+b \tan (c+d x)}{a+\sqrt {-b^2}}}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.15, antiderivative size = 159, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3593, 774, 138}
\begin {gather*} \frac {\sec (c+d x) (a+b \tan (c+d x))^{n+1} F_1\left (n+1;-\frac {1}{2},-\frac {1}{2};n+2;\frac {a+b \tan (c+d x)}{a-\sqrt {-b^2}},\frac {a+b \tan (c+d x)}{a+\sqrt {-b^2}}\right )}{b d (n+1) \sqrt {1-\frac {a+b \tan (c+d x)}{a-\sqrt {-b^2}}} \sqrt {1-\frac {a+b \tan (c+d x)}{a+\sqrt {-b^2}}}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 138
Rule 774
Rule 3593
Rubi steps
\begin {align*} \int \sec ^3(c+d x) (a+b \tan (c+d x))^n \, dx &=\frac {\sec (c+d x) \text {Subst}\left (\int (a+x)^n \sqrt {1+\frac {x^2}{b^2}} \, dx,x,b \tan (c+d x)\right )}{b d \sqrt {\sec ^2(c+d x)}}\\ &=\frac {\sec (c+d x) \text {Subst}\left (\int x^n \sqrt {1-\frac {x}{a-\sqrt {-b^2}}} \sqrt {1-\frac {x}{a+\sqrt {-b^2}}} \, dx,x,a+b \tan (c+d x)\right )}{b d \sqrt {1-\frac {a+b \tan (c+d x)}{a-\frac {b^2}{\sqrt {-b^2}}}} \sqrt {1-\frac {a+b \tan (c+d x)}{a+\frac {b^2}{\sqrt {-b^2}}}}}\\ &=\frac {F_1\left (1+n;-\frac {1}{2},-\frac {1}{2};2+n;\frac {a+b \tan (c+d x)}{a-\sqrt {-b^2}},\frac {a+b \tan (c+d x)}{a+\sqrt {-b^2}}\right ) \sec (c+d x) (a+b \tan (c+d x))^{1+n}}{b d (1+n) \sqrt {1-\frac {a+b \tan (c+d x)}{a-\sqrt {-b^2}}} \sqrt {1-\frac {a+b \tan (c+d x)}{a+\sqrt {-b^2}}}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains complex when optimal does not.
time = 4.22, size = 306, normalized size = 1.92 \begin {gather*} \frac {2 (a-i b) (a+i b) (2+n) F_1\left (1+n;-\frac {1}{2},-\frac {1}{2};2+n;\frac {a+b \tan (c+d x)}{a-i b},\frac {a+b \tan (c+d x)}{a+i b}\right ) \sec (c+d x) (a+b \tan (c+d x))^{1+n}}{b d (1+n) \left (2 \left (a^2+b^2\right ) (2+n) F_1\left (1+n;-\frac {1}{2},-\frac {1}{2};2+n;\frac {a+b \tan (c+d x)}{a-i b},\frac {a+b \tan (c+d x)}{a+i b}\right )-\left ((a-i b) F_1\left (2+n;-\frac {1}{2},\frac {1}{2};3+n;\frac {a+b \tan (c+d x)}{a-i b},\frac {a+b \tan (c+d x)}{a+i b}\right )+(a+i b) F_1\left (2+n;\frac {1}{2},-\frac {1}{2};3+n;\frac {a+b \tan (c+d x)}{a-i b},\frac {a+b \tan (c+d x)}{a+i b}\right )\right ) (a+b \tan (c+d x))\right )} \end {gather*}
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.31, size = 0, normalized size = 0.00 \[\int \left (\sec ^{3}\left (d x +c \right )\right ) \left (a +b \tan \left (d x +c \right )\right )^{n}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \left (a + b \tan {\left (c + d x \right )}\right )^{n} \sec ^{3}{\left (c + d x \right )}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+b\,\mathrm {tan}\left (c+d\,x\right )\right )}^n}{{\cos \left (c+d\,x\right )}^3} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________